home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Resources / Burning & Media / GB-PVR 1.2.13 / GBPVR10213.msi / Cabs.w1.cab / GuideListingDiv.cs652 < prev    next >
Text File  |  2007-01-28  |  1KB  |  60 lines

  1. /// <summary>
  2. /// This object is a Div tag that is used in displaying guide information
  3. /// </summary>
  4. namespace gbweb.classes
  5. {
  6.     public class GuideListingDiv
  7.     {
  8.         private const string beginDiv = "<div ";
  9.         private const string beginDivId = " id=\"";
  10.         private string divId = "";
  11.         private const string endDivId = "\"";
  12.         private const string beginDivClass = " class=\"";
  13.         private string divClass = "";
  14.         private const string endDivClass = "\"";
  15.         private const string endDiv = ">";
  16.         private const string closeDiv = "</div>";
  17.  
  18.  
  19.         public GuideListingDiv()
  20.         {
  21.         }
  22.         
  23.         public GuideListingDiv(string DivId, string DivClass)
  24.         {
  25.             divId = DivId;
  26.             divClass = DivClass;
  27.         }
  28.  
  29.  
  30.         public string getEndDiv()
  31.         {
  32.  
  33.             return closeDiv;
  34.  
  35.         }
  36.  
  37.         public string getStartDiv()
  38.         {
  39.             string divStart = string.Empty;
  40.             divStart += beginDiv;
  41.             if (divId != "")
  42.             {
  43.                 divStart += beginDivId;
  44.                 divStart += divId;
  45.                 divStart += endDivId;
  46.             }
  47.             if (divClass != "")
  48.             {
  49.                 divStart += beginDivClass;
  50.                 divStart += divClass;
  51.                 divStart += endDivClass;
  52.             }
  53.             divStart += endDiv;
  54.  
  55.             return divStart;
  56.  
  57.         }
  58.     }
  59. }
  60.